package com.rytx.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.rytx.system.mapper.PThemeMapper;
import com.rytx.system.domain.ysp.PTheme;
import com.rytx.system.service.IPThemeService;

/**
 * 商品题材Service业务层处理
 * 
 * @author rytx
 * @date 2024-05-19
 */
@Service
public class PThemeServiceImpl implements IPThemeService 
{
    @Autowired
    private PThemeMapper pThemeMapper;

    /**
     * 查询商品题材
     * 
     * @param valId 商品题材主键
     * @return 商品题材
     */
    @Override
    public PTheme selectPThemeByValId(Long valId)
    {
        return pThemeMapper.selectPThemeByValId(valId);
    }

    /**
     * 查询商品题材列表
     * 
     * @param pTheme 商品题材
     * @return 商品题材
     */
    @Override
    public List<PTheme> selectPThemeList(PTheme pTheme)
    {
        return pThemeMapper.selectPThemeList(pTheme);
    }

    /**
     * 新增商品题材
     * 
     * @param pTheme 商品题材
     * @return 结果
     */
    @Override
    public int insertPTheme(PTheme pTheme)
    {
        return pThemeMapper.insertPTheme(pTheme);
    }

    /**
     * 修改商品题材
     * 
     * @param pTheme 商品题材
     * @return 结果
     */
    @Override
    public int updatePTheme(PTheme pTheme)
    {
        return pThemeMapper.updatePTheme(pTheme);
    }

    /**
     * 批量删除商品题材
     * 
     * @param valIds 需要删除的商品题材主键
     * @return 结果
     */
    @Override
    public int deletePThemeByValIds(Long[] valIds)
    {
        return pThemeMapper.deletePThemeByValIds(valIds);
    }

    /**
     * 删除商品题材信息
     * 
     * @param valId 商品题材主键
     * @return 结果
     */
    @Override
    public int deletePThemeByValId(Long valId)
    {
        return pThemeMapper.deletePThemeByValId(valId);
    }
}
